<template>
    <div>
        <div id="myeditor">

        </div>
    </div>
</template>
<script setup>
import {ref,onMounted} from 'vue';
import WangEditor from 'wangeditor';
onMounted(() => {
       // 创建富文本编辑器实例
     let myEditor =  new WangEditor('#myeditor');
     console.log(myEditor)
     myEditor.config.uploadImgShowBase64 = true
  // 隐藏网络图片
     myEditor.config.showLinkImg = false
     myEditor.create();
    //获取 富文本编辑内容
    // myEditor.text.html();
})
</script>
<style>
#myeditor{
    width: 100%;
    height: 400px;
}
</style>